package com.xkk.service;

import com.xkk.pojo.Employee;
import com.xkk.pojo.Register;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Mapper
@Repository
@ResponseBody
public interface RegisterService {
    /*注册成功*/
    @Insert("insert into register (username,password) values(#{username},#{password})")
    int addregister(Register register);

    @Select("select*from register")
    List<Register> selectAllregister();

    //根据id删除员工信息
    @Delete("delete from register where id=#{id}")
    int deleteregister(int id);



}
